home *** CD-ROM | disk | FTP | other *** search
/ Nebula 2 / Nebula Two.iso / NextAnswers / 1433_downloading_PostScript_to_WindowServer.rtf < prev    next >
Text File  |  1993-11-08  |  1KB  |  43 lines

  1. {\rtf0\ansi{\fonttbl\f0\fnil Times-Roman;\f1\fmodern Courier;\f3\fmodern Ohlfs;}
  2. \paperw11700
  3. \paperh9540
  4. \margl120
  5. \margr120
  6. \pard\tx960\tx1920\tx2880\tx3840\tx4800\tx5760\tx6720\tx7680\tx8640\tx9600\f0\b0\i0\ulnone\fs28\fc0\cf0 Q:  When can I download PostScript code to the Window Server?  Can I use the 
  7. \b +initialize
  8. \b0  methods for factory objects?\
  9. \
  10. A:  Object class 
  11. \b +initialize
  12. \b0  methods cannot download PostScript code to the Window Server because they are run before the connection to the Server has been established.  
  13. \b Initialize
  14. \b0  messages for classes always get sent before any other messages are delivered, specifically before 
  15. \f1\fs24 [Application new]
  16. \f0\fs28  has been executed.  But 
  17. \f1\fs24 [Application new]
  18. \f0\fs28  is what connects the program to the Server.\
  19. \
  20. A good time to download code to the server is after 
  21. \f1\fs24 [Application new]
  22. \f0\fs28  and loading the nib section, but before the application starts running.  In your 
  23. \b main
  24. \b0 (), after sending the  
  25. \b loadNibSection
  26. \b0  method, sent a 
  27. \b setUp
  28. \b0  message, like this:\
  29. \
  30.  
  31. \f1\fs24     [NXApp loadNibSection:"MyNibFile.nib" owner:NXApp];\
  32.     [NXGetNamedObject("MyObj", NXApp) setUp];\
  33.     \
  34.  
  35. \f0\b\fs28 setUp
  36. \b0  is an instance method that downloads PostScript code to the Window Server.\
  37. \
  38. QA29\
  39. \
  40. Valid for 1.0, 2.0, 3.0\
  41. \
  42.  
  43.